<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <link rel="stylesheet" href="style.css">
    <style>
        ul{
            width:200px; height:300px;
            /* border: solid 2px #000; */
            transform-style: preserve-3d;
            position: absolute;
            left:0; right:0; top:0;bottom:0; margin: auto;
            transform: rotate(15deg) rotateY(20deg);
            animation: go 3s linear infinite;
        }
        ul li{
            width:200px; height:300px;
            background: red;
            position: absolute;
        }
        ul li:nth-child(1){
            background: blue;
            transform: rotateY(36deg) translateZ(400px);
        }
        ul li:nth-child(2){
            background: olive;
            transform: rotateY(72deg) translateZ(400px);
        }
        ul li:nth-child(3){
            background: pink;
            transform: rotateY(108deg) translateZ(400px);
        }
        ul li:nth-child(4){
            background: red;
            transform: rotateY(144deg) translateZ(400px);
        }
        ul li:nth-child(5){
            background: yellow;
            transform: rotateY(180deg) translateZ(400px);
        }
        ul li:nth-child(6){
            background: green;
            transform: rotateY(216deg) translateZ(400px);
        }
        ul li:nth-child(7){
            background: palevioletred;
            transform: rotateY(252deg) translateZ(400px);
        } 
         ul li:nth-child(8){
            background: orangered;
            transform: rotateY(288deg) translateZ(400px);
        }
        ul li:nth-child(9){
            background: #333;
            transform: rotateY(324deg) translateZ(400px);
        }
         ul li:nth-child(10){
            background: brown;
            transform: rotateY(360deg) translateZ(400px);
        }
        @keyframes go{
            0%{
                transform: rotateX(25deg) rotateY(15deg);
            }
            50%{
                transform: rotateX(45deg) rotateY(180deg);
            }
            100%{
                transform: rotateX(15deg) rotateY(360deg);
            }
        }
    </style>
</head>
<body>
   
        <ul>
            <li>1</li>
            <li>2</li>
            <li>3</li>
            <li>4</li>
            <li>5</li>
            <li>6</li>
            <li>7</li>
            <li>8</li>
            <li>9</li>
            <li>10</li>
        </ul>
 
</body>
</html>